package com.example.thirdstage_project.service.impl;


import com.baomidou.mybatisplus.core.conditions.Wrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.example.thirdstage_project.dao.ProjectCategoryDao;
import com.example.thirdstage_project.entity.Project;
import com.example.thirdstage_project.entity.ProjectCategory;
import com.example.thirdstage_project.ov.ProjectCategoryExpertOV;
import com.example.thirdstage_project.service.ProjectCategoryService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;


/**
 * 项目类别表(ProjectCategory)表服务实现类
 *
 * @author makejava
 * @since 2022-11-28 20:51:25
 */
@Service
public class ProjectCategoryServiceImpl extends ServiceImpl<ProjectCategoryDao, ProjectCategory> implements ProjectCategoryService {
    @Autowired
    private ProjectCategoryDao projectCategoryDao;


    @Override
    public List<ProjectCategoryExpertOV> select() {
        return projectCategoryDao.select();
    }

    @Override
    public List<ProjectCategoryExpertOV> selectFour() {
        return projectCategoryDao.selectfour();
    }

    @Override
    public List<ProjectCategory> selectByPid(int categoryid) {
        return projectCategoryDao.selectByPid(categoryid);
    }

    @Override
    public boolean updateProject(Project project) {
        return projectCategoryDao.updateProject(project)>0;
    }

    @Override
    public boolean updatePro(ProjectCategory project) {
        return projectCategoryDao.updatePro(project)>0;
    }

}
